package org.abratuhi.kvngroupware.widget;

import java.util.Properties;

import org.abratuhi.kvngroupware.network.Message;
import org.abratuhi.kvngroupware.network.MessageSender;

@SuppressWarnings("serial")
public abstract class AbstractWorkWidget extends AbstractWidget{
	
	protected Properties locale;
	
	protected String frameid;
	protected Message exitmessage;
	
	public AbstractWorkWidget(String frameid, String frametitle, MessageSender sender, Properties locale){
		super(frametitle, sender);
		
		this.frameid = frameid;
		this.locale = locale;
		
	}
	
	public void setExitMessage(Message message){
		this.exitmessage = message;
	}

	@Override
	public void onFrameClose() {
		sender.sendMessage(exitmessage);
	}
	
	

}
